package com.exam.controller;

import com.exam.pojo.vo.QuestionCategoryVO;
import com.exam.service.IQuestionCategoryService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/cates")
@RequiredArgsConstructor
@Api(tags = "题目分类")
public class QuestionCategoryController {


    private final IQuestionCategoryService questionCategoryService;


    @GetMapping
    @ApiOperation("查询题目分类列表")
    public List<QuestionCategoryVO> list(@RequestParam(required = false) String uuid){
        return  questionCategoryService.list(uuid);
    }

}
